<template>
  <div></div>
</template>

<script>
import Fuse from 'fuse.js'
export default {
  data() {
    return {
      fuse: undefined
    }
  },

  computed: {
    routes() {
      return this.$store.getters.routes
    }
  },

  methods: {
    initFuse(list) {
      this.fuse = new Fuse(list, {
        shouldSort: true,
        threshold: 0.4,
        location: 0,
        distance: 100,
        maxPatternLength: 32,
        minMatchCharLength: 1,
        keys: [
          {
            name: 'title',
            weight: 0.7
          },
          {
            name: 'path',
            weight: 0.3
          }
        ]
      })
    }
  }
}
</script>

<style lang="scss" scoped></style>
